Skip to main content
This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal

Notes/Domino 6 and 7 Forum

Notes/Domino 6 and 7 Forum


  

PreviousPrevious NextNext

RE: Unique Field Lookup Issue
~Umberto Nongeroson 14.Jan.04 03:09 AM a Web browser
Domino Designer All Releases All Platforms


It's nice that you're thinking about checking uniqueness even if the document is not new, but this formula isn't going to do it either. If the field is editable when the document is not new (and I can think of no other reason to check for uniqueness in that case if not!) there's no way to know whether the one document you find with your lookup, is this document or some other. If it's some other, you do want to display an error, but in either case the matching count is 1.

Furthermore, it's a big waste of time to do the lookup at the beginning of the formula. First check @IsDocBeingSaved, for efficiency.

That said, there's basically nothing wrong with the formula in the original post, per se. It doesn't handle the case of subsequent saves, but I choose to believe Karen's taking care of that by making the field non-editable on subsequent opens. I suspect the @DbLookup is always returning an error because the design of the view is wrong for doing that particular lookup. The view has to exist, for instance, and must sorted by the field whose value you're searching for.

If you're not sure what the problem is, you could put a button on your form that just does @StatusBar(@Text(@DbLookup("":"NoCache"; ""; "All Reqs"; RequestNo; "RequestNo")))

BTW the recognized indication for "the current database" is "", not "":"". The latter will work, but why use more complex expressions than you need?




Unique Field Lookup Issue (~John Cisgeroth... 13.Jan.04)
. . RE: Unique Field Lookup Issue (~Mario Lopkiste... 13.Jan.04)
. . RE: Unique Field Lookup Issue (~Yentl Cisniter... 13.Jan.04)
. . . . RE: Unique Field Lookup Issue (~Bill Frokimari... 14.Jan.04)
. . . . . . Unique Field Lookup Issue - Thanks!... (~John Cisgeroth... 14.Jan.04)


Document Options






  Document options
Print this pagePrint this page

Search this forum

Forum views and search


  Forum views and search
Date (threaded)
Date (flat)
With excerpt
Category
Platform
Release
Advanced search

Member Tools


RSS Feeds

 RSS feedsRSS
All forum posts RSS
All main topics RSS